package com.nthink.indicators.mapper.qualitymanagement;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.nthink.indicators.pojo.pie.PieDataModel;
import com.nthink.indicators.pojo.qualitymanagement.BaseIndex;
import com.nthink.indicators.pojo.qualitymanagement.ClinicalPathway;
import io.swagger.annotations.ApiModelProperty;
import org.apache.ibatis.annotations.Mapper;

import java.util.Date;
import java.util.List;

@Mapper
public interface ClinicalPathwayMapper extends BaseMapper<ClinicalPathway> {
    //医院临床路径总病种数
    public Integer getTypeCount();

    //医院临床路径总入组例数
    public Integer getTotalCount(Date startTime, Date endTime);

    //入组后完成例数
    public Integer getCompleteCount(Date startTime, Date endTime);

    //变异例数
    public Integer getVariationCount(Date startTime, Date endTime);

    //退出例数
    public Integer getExitCount(Date startTime, Date endTime);

    //未入例数
    public Integer getNotCount(Date startTime, Date endTime);

    //平均住院日
    public Double getAvgInCount(Date startTime, Date endTime);

    //平均住院费用
    public Double getAvgFee(Date startTime, Date endTime);

    //死亡率
    public Double getDeathRate(Date startTime, Date endTime);

    //各病种临床路径入组例数
    public List<PieDataModel> getDiagnosisInfo(Date startTime, Date endTime);

    //各组比率
    public List<PieDataModel> getCateInfo(Date startTime, Date endTime);
}


